<?php
namespace app\common\validate;

use think\Validate;

class Activity extends Validate
{
    protected $rule = [
        'name'  =>  'require',
        'start_time' => 'require',
        'population' => 'require',
        'address' => 'require',
        'lat' => 'require',
        'lng' => 'require',
        'is_aa' => 'require',
        'is_group_chat' => 'require',
        'msg' => 'require',
        'image_1' => 'require',
        'image_2' => 'require',
        'image_3' => 'require',
    ];

    protected $message = [
        'name.require' => '活动名称不能为空',
        'start_time.require' => '开始时间不能为空',
        'population.require' => '活动人数上限不能为空',
        'address.require' => '活动地址不能为空',
        'lat.require' => '活动地址定位失败',
        'lng.require' => '活动地址定位失败',
        'is_aa.require' => '请选择是否AA制',
        'is_group_chat.require' => '请选择是否开启群聊',
        'msg.require' => '活动说明不能为空',
        'image_1.require' => '请上传三张图片',
        'image_2.require' => '请上传三张图片',
        'image_3.require' => '请上传三张图片',
    ];

}